#@adminLayout()
#define main()
<div class="jbolt_page" data-key="#(pmkey)"  >
    <div class="jbolt_page_title">
        <div class="row">
            <div class="col-4">
                <h1>会员管理</h1>
                <span> #(pageData.totalRow?? 0) 条记录</span>
            </div>
            <div class="col-5">
                <form class="form-inline" id="memberFormIndex" action="/auth/mall/member"  data-pjaxsubmit  method="get">
                    <input type="text" autocomplete="off"  class="form-control"  placeholder="输入关键字搜索" id="keywords" name="keywords" value="#(keywords??)" />
                    <input type="hidden" name="isDelete" value="#(isDelete?? false)"/>
                    <button  type="button" onclick="normaMemberlData()" class="btn btn-light" ><i class="fa fa-search"></i> 查询</button>
                    <!--<button  onclick="Testreset()" class="btn btn-light"  ><i class="fa fa-refresh"></i> 重置</button>-->
<!--                    <button  type="button" onclick="trashMemberData()" class="btn btn-#((isDelete?? && isDelete=='true')?'danger':'light')" ><i class="fa fa-trash"></i> 回收站(#(deleteCount?? 0))</button>-->
                </form>
            </div>
        </div>
    </div>
    <div class="jbolt_page_content">
        <div class="table-responsive">
            <table class="table table-bordered table-hover table-striped table-center">
                <thead>
                <tr>
                    <th style="width: 60px">序号</th><th style="width: 100px">称呼</th>
                    <th style="width: 100px">手机号</th><th style="width: 100px">Openid</th>
                    <th  style="width: 160px">创建时间</th><th style="width: 60px">分销商</th>
                    <th style="width: 30px">积分</th><th style="width: 30px">余额（元）</th>
                    <th style="width: 30px">昵称</th>
                    <th style="width: 30px">积分ID</th>
                    <th style="width: 60px">操作</th>
                </tr>
                </thead>
                <tbody>
                #if(pageData)
                #for(data:pageData.list)
                <tr>
                    <td>#(for.index+1)</td>
                    <td>#(data.title??)</td>
                    <td>#(data.mobile)</td>
                    <td>#(data.openid_jmd??)</td>
                    <td>#(MyUtil.get_date(data.reg_time))</td>
                    <td>#(data.from??)</td>
                    <td>#(MyUtil.get_price_string(data.spreader_credit??)??0.00)</td>
                    <td>#(MyUtil.get_price_string(data.balance??)??0.00)</td>
                    <td>#(data.nickname??)</td>
                    <td>#(data.spreader_id??)</td>
                    <td>

                        <a  tooltip  title="编辑"  class="jbolt_table_delbtn" data-confirm  data-jboltlayertrigger  href="/auth/mall/member/modity/#(data.id)" class="btn btn-info"   data-width="500"  data-noclose><i class="fa fa-pencil c-primary"></i></a>

                    </td>
                </tr>
                #end
                #end
                <tr>
                    总计余额: #(MyUtil.get_price_string(amount_balance??)??0.00)
                    总计积分: #(MyUtil.get_price_string(amount_credit??)??0.00)
                </tr>
                </tbody>
            </table>
        </div>
        #include("/_view/_admin/common/_page.html",pageEleId="memberPageIndex")
    </div>
</div>
</div>
</div>
#end
#define js()
<script type="text/javascript">

    var memberFormIndex=$("#memberFormIndex");

    $(function(){
        initPage("memberPageIndex",#(pageData.totalPage??),#(pageData.pageNumber??),"memberFormIndex");
    });


    /**
     * 普通查询
     */
    function normaMemberlData(){
        memberFormIndex.find("[name='isDelete']").val(false);
        memberFormIndex.submit();
    }

    /**
     * 查回收站
     */
    function trashMemberData(){
        memberFormIndex.find("[name='isDelete']").val(true);
        memberFormIndex.submit();
    }

    //测试可刷新 -- 提交表单
    function RefreshsubmitForm(formEId){
        var form=getRealJqueryObject(formEId);
        if(FormChecker.check(form)){
            // LayerMsgBox.loading("执行中...");
            // var formData=form.serialize();
            var url=form.action;
            form.ajaxSubmit({
                type:"post",
                url:url,
                success:function(ret){
                    if(ret.state=="ok"){
                        LayerMsgBox.success(ret.msg,500,function(){
                            refreshPjaxContainer();
                        });
                    }else{
                        LayerMsgBox.alert(ret.msg,2);
                    }
                }
            });
        }
        return false;
    }

</script>



#end

